#ifndef __UTILS_H__
#define __UTILS_H__

#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include "ohos_types.h"
#include "cmsis_os2.h"

void mm_strcat(char * t,char * s);

void mm_split(char *src,const char *separator,char **dest,int *num);

void mm_print_hex(uint8_t str[],int size);
void mm_print(uint8_t str[],int size);
int mm_find_hex(char * src,char hex,int start,int length);

// FLASH 读写
void mm_flash_read(uint32_t addr,uint8_t *buf,uint16_t len);
void mm_flash_write(uint32_t addr,uint8_t *buf,uint16_t len);

// 日志打印
void mm_LogPrint(const char *format, ...);

#endif